<?php $this->load->view('common/admin_header');?>
<div class="block">
  <div class="block_head">
    <div class="bheadl"></div>
    <div class="bheadr"></div>
    <h2><?=$lang['global_lable_36']?></h2>
    <ul>
      <li><a href="<?=site_url('admins/users_group')?>"><?=$lang['global_lable_41']?></a></li>
    </ul>
  </div>
  <!-- .block_head ends -->
  <div class="block_content">
    <?php $this->load->view('common/notify');?>
  <form id="form" action="<?=site_url('admins/users_group/modify');?>" method="post" enctype="multipart/form-data">
    <input type="hidden" name="edit_id" value='<?=set_value('edit_id',isset($edit_id)?$edit_id:'')?>' />
      <p>
        <label><?=$lang['admin_lable_27']?>(繁體):</label>
        <input type="text" class="text small" name="name" value='<?=set_value('name',isset($name)?$name:'')?>'/>
        <span class="note required">*<?=$lang['global_lable_35']?></span>
      </p>
      <p>
        <label><?=$lang['admin_lable_27']?>(English):</label>
        <input type="text" class="text small" name="ename" value='<?=set_value('ename',isset($ename)?$ename:'')?>'/>
        <span class="note required">*<?=$lang['global_lable_35']?></span>
      </p>
      <p>
        <label><?=$lang['admin_lable_28']?>:</label>
        <?php if(isset($permissions) && is_array($permissions)):?>
        <div class="scrollbox">
          <?php foreach($permissions as $key=>$per):?>
           <div class="<?=$key%2?'even':'odd'?>">
             <input type="checkbox" <?=isset($permission) && in_array($per,$permission) || $per=='index'?'checked':'' ?> <?=set_checkbox('permission[]',$per)?> value="<?=$per?>" name="permission[]"><?=isset($perstring[$per])?$perstring[$per]:$per?>
           </div>
          <?php endforeach;?>
         </div>
         <a onclick="$(this).parent().find(':checkbox').attr('checked', true);" style="cursor:pointer"><?=$lang['admin_lable_29']?></a>
         /
         <a onclick="$(this).parent().find(':checkbox').attr('checked', false);" style="cursor:pointer"><?=$lang['admin_lable_30']?></a>
         <?php endif;?>
         <span class="note required">*<?=$lang['global_lable_35']?></span>
      </p>
      <p>
        <input class="btn btn-primary" type="submit" name="btn_save" value="<?=$lang['global_lable_12']?>" />
        <input class="btn" type="reset" value="<?=$lang['global_lable_13']?>"/>
      </p>
    </form>
  </div>
  <!-- .block_content ends -->
  <div class="bendl"></div>
  <div class="bendr"></div>
</div>
<!-- .block ends -->
<?php $this->load->view('common/admin_footer');?>